<div navbar ng-init="currentItem='service'"></div>
<div ng-show="Auth.processing||!loaded">
    <div loading></div>
</div>

<div id="main" ng-show="!Auth.processing&&loaded" style="display:none">
    <div class="module-header">
        <h3>服务管理</h3>
    </div>

    <div class="tabbable" ng-init="loadInfo('service.**')">
        <ul class="nav nav-tabs">
            <li ng-class="'active' | iftrue:activeTabName=='http'"><a href="#http" ng-click="sec('http')" data-toggle="tab">HTTP</a></li>
            <li ng-class="'active' | iftrue:activeTabName=='ftp'"><a href="#ftp" ng-click="sec('ftp')" data-toggle="tab">FTP</a></li>
            <li ng-class="'active' | iftrue:activeTabName=='database'"><a href="#database" ng-click="sec('database')" data-toggle="tab">数据库</a></li>
            <li ng-class="'active' | iftrue:activeTabName=='storage'"><a href="#storage" ng-click="sec('storage')" data-toggle="tab">文件存储</a></li>
            <li ng-class="'active' | iftrue:activeTabName=='appengine'"><a href="#appengine" ng-click="sec('appengine')" data-toggle="tab">脚本引擎</a></li>
            <li ng-class="'active' | iftrue:activeTabName=='mail'"><a href="#mail" ng-click="sec('mail')" data-toggle="tab">邮件</a></li>
            <li ng-class="'active' | iftrue:activeTabName=='system'"><a href="#system" ng-click="sec('system')" data-toggle="tab">系统</a></li>
        </ul>
        <div class="tab-content">
            <div class="tab-pane table-responsive" ng-class="'active' | iftrue:activeTabName=='http'" id="http">
                <table class="table table-hover">
                    <thead>
                        <tr>
                            <th colspan="4">HTTP 服务器软件</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td>Apache</td>
                            <td ng-bind-html-unsafe="info['service.httpd']['status'] | service.status"></td>
                            <td class="muted">广泛使用的开源 HTTP 服务器软件</td>
                            <td>
                                <div srvminiop ng-init="name='Apache';service='httpd';urlname='apache'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td style="width:100px">Nginx</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.nginx']['status'] | service.status"></td>
                            <td class="muted">高性能的开源 HTTP 服务器软件</td>
                            <td style="width:150px">
                                <div srvminiop ng-init="name='Nginx';service='nginx';urlname='nginx'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td style="width:100px">Tomcat(开发中)</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.tomcat']['status'] | service.status"></td>
                            <td class="muted">小型的轻量级 JSP 引擎应用</td>
                            <td style="width:150px">
                                <div srvminiop ng-init="name='Tomcat';service='tomcat';urlname='tomcat'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td style="width:100px">Lighttpd(开发中)</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.lighttpd']['status'] | service.status"></td>
                            <td class="muted">快速灵活高性能的开源 HTTP 服务器软件</td>
                            <td style="width:150px">
                                <div srvminiop ng-init="name='Lighttpd';service='lighttpd';urlname='lighttpd'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td style="width:100px">Tengine(开发中)</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.tengine']['status'] | service.status"></td>
                            <td class="muted">基于 Nginx 的高效稳定安全的 HTTP 服务器软件</td>
                            <td style="width:150px">
                                <div srvminiop ng-init="name='Tengine';service='tengine';urlname='tengine'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td style="width:100px">Caddy(开发中)</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.caddy']['status'] | service.status"></td>
                            <td class="muted">自动 SSL 的 HTTP 服务器软件</td>
                            <td style="width:150px">
                                <div srvminiop ng-init="name='Caddy';service='caddy';urlname='caddy'"></div>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
            <div class="tab-pane table-responsive" ng-class="'active' | iftrue:activeTabName=='ftp'" id="ftp">
                <table class="table table-hover">
                    <thead>
                        <tr>
                            <th colspan="4">FTP 服务器软件</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td style="width:100px">vsftpd</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.vsftpd']['status'] | service.status"></td>
                            <td class="muted">安全快速的 FTP 服务器</td>
                            <td style="width:150px">
                                <div srvminiop ng-init="name='vsftpd';service='vsftpd';urlname='vsftpd'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td style="width:100px">ProFTPD</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.proftpd']['status'] | service.status"></td>
                            <td class="muted">安全简单的 FTP 服务器</td>
                            <td style="width:150px">
                                <div srvminiop ng-init="name='proftpd';service='proftpd';urlname='proftpd'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td style="width:100px">Pure-FTPd</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.pure-ftpd']['status'] | service.status"></td>
                            <td class="muted">快速稳定全功能的 FTP 服务器</td>
                            <td style="width:150px">
                                <div srvminiop ng-init="name='Pure-FTPd';service='pure-ftpd';urlname='pureftpd'"></div>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
            <div class="tab-pane table-responsive" ng-class="'active' | iftrue:activeTabName=='database'" id="database">
                <table class="table table-hover">
                    <thead>
                        <tr>
                            <th colspan="4">数据库服务</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td style="width:100px">MariaDB</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.mariadb']['status'] | service.status"></td>
                            <td class="muted">MySQL的一个分支，主要由开源社区在维护</td>
                            <td style="width:150px">
                                <div srvminiop ng-init="name='MariaDB';service='mariadb';urlname='mariadb'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td>MySQL</td>
                            <td ng-bind-html-unsafe="info['service.mysqld']['status'] | service.status"></td>
                            <td class="muted">最流行的开源关系型数据库服务器</td>
                            <td>
                                <div srvminiop ng-init="name='MySQL';service='mysqld';urlname='mysql'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td>Redis</td>
                            <td ng-bind-html-unsafe="info['service.redis']['status'] | service.status"></td>
                            <td class="muted">高性能内存KV数据库</td>
                            <td>
                                <div srvminiop ng-init="name='Redis';service='redis';urlname='redis'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td>Memcache</td>
                            <td ng-bind-html-unsafe="info['service.memcached']['status'] | service.status"></td>
                            <td class="muted">高性能的分布式内存对象缓存系统</td>
                            <td>
                                <div srvminiop ng-init="name='Memcache';service='memcached';urlname='memcache'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td>MongoDB</td>
                            <td ng-bind-html-unsafe="info['service.mongod']['status'] | service.status"></td>
                            <td class="muted">分布式高性能的NOSQL数据库服务器</td>
                            <td>
                                <div srvminiop ng-init="name='MongoDB';service='mongod';urlname='mongodb'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td>PostgreSQL[未完成]</td>
                            <td ng-bind-html-unsafe="info['service.postgresql']['status'] | service.status"></td>
                            <td class="muted">功能强大的开源数据库</td>
                            <td>
                                <div srvminiop ng-init="name='PostgreSQL';service='postgresql';urlname='postgresql'"></div>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
            <div class="tab-pane table-responsive" ng-class="'active' | iftrue:activeTabName=='storage'" id="storage">
                <table class="table table-hover">
                    <thead>
                        <tr>
                            <th colspan="4">文件存储服务</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td style="width:100px">MinIO</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.minio']['status'] | service.status"></td>
                            <td class="muted">MinIO是一个开源的轻量级对象存储服务</td>
                            <td style="width:150px">
                                <div srvminiop ng-init="name='MinIO';service='minio';urlname='minio'"></div>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
            <div class="tab-pane table-responsive" ng-class="'active' | iftrue:activeTabName=='appengine'" id="appengine">
                <table class="table table-hover">
                    <thead>
                        <tr>
                            <th colspan="4">应用/脚本引擎</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td style="width:100px">PHP</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.php-fpm']['status'] | service.status"></td>
                            <td class="muted">PHP 脚本解析器</td>
                            <td style="width:150px">
                                <div srvminiop ng-init="name='PHP';service='php-fpm';urlname='php'"></div>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
            <div class="tab-pane table-responsive" ng-class="'active' | iftrue:activeTabName=='mail'" id="mail">
                <table class="table table-hover">
                    <thead>
                        <tr>
                            <th colspan="4">邮件服务</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td style="width:100px">Sendmail</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.sendmail']['status'] | service.status"></td>
                            <td class="muted">邮件传输服务</td>
                            <td style="width:150px">
                                <div srvminiop ng-init="name='Sendmail';service='sendmail';urlname='sendmail'"></div>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
            <div class="tab-pane table-responsive" ng-class="'active' | iftrue:activeTabName=='system'" id="system">
                <table class="table table-hover">
                    <thead>
                        <tr>
                            <th colspan="4">系统服务</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td style="width:100px">SSH</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.sshd']['status'] | service.status"></td>
                            <td class="muted">远程连接服务器</td>
                            <td style="width:150px">
                                <div srvminiop ng-init="name='SSH';service='sshd';urlname='ssh'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td>iptables</td>
                            <td ng-bind-html-unsafe="info['service.iptables']['status'] | service.status"></td>
                            <td class="muted">Linux 防火墙</td>
                            <td>
                                <div srvminiop ng-init="name='iptables';service='iptables';urlname='iptables'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td>Cron</td>
                            <td ng-bind-html-unsafe="info['service.crond']['status'] | service.status"></td>
                            <td class="muted">定时任务管理服务器</td>
                            <td>
                                <div srvminiop ng-init="name='Cron';service='crond';urlname='cron'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td style="width:100px">Named</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.named']['status'] | service.status"></td>
                            <td class="muted">DNS 域名解析服务器</td>
                            <td style="width:100px">
                                <div srvminiop ng-init="name='named';service='named';urlname='named'"></div>
                            </td>
                        </tr>
                        <tr>
                            <td style="width:100px">Samba</td>
                            <td style="width:60px" ng-bind-html-unsafe="info['service.smb']['status'] | service.status"></td>
                            <td class="muted">文件资源共享服务器</td>
                            <td style="width:100px">
                                <div srvminiop ng-init="name='samba';service='smb';urlname='samba'"></div>
                            </td>
                        </tr>
                        <tr style="display:none" ng-show="info['server.virt'] != 'Virtuozzo/OpenVZ'">
                            <td>NTP</td>
                            <td ng-bind-html-unsafe="info['service.ntpd']['status'] | service.status"></td>
                            <td class="muted">时间同步服务</td>
                            <td>
                                <div srvminiop ng-init="name='NTP';service='ntpd';urlname='ntp'"></div>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
        </div>
    </div>
</div>